nlp_architect.nn.tensorflow.python.keras package

Submodules

nlp_architect.nn.tensorflow.python.keras.callbacks module

class nlp_architect.nn.tensorflow.python.keras.callbacks.ConllCallback(x, y, y_vocab, batch_size=1)[source]

Bases: tensorflow.python.keras.callbacks.Callback

A Tensorflow(Keras) Conlleval evaluator. Runs the conlleval script for given x and y inputs. Prints Conlleval F1 score on the end of each epoch.

Parameters:
  • x – features matrix
  • y – labels matrix
  • y_vocab (dict) – int-to-str labels lexicon
  • batch_size (int, optional) – batch size
on_epoch_end(epoch, logs=None)[source]

Module contents